/*
 * Flowable CMMN REST API
 * # flowable / flowəb(ə)l /    - a compact and highly efficient workflow and Business Process Management (BPM) platform for developers, system admins and business users.  - a lightning fast, tried and tested BPMN 2 process engine written in Java. It is Apache 2.0 licensed open source, with a committed community.  - can run embedded in a Java application, or as a service on a server, a cluster, and in the cloud. It integrates perfectly with Spring. With a rich Java and REST API, it is the ideal engine for orchestrating human or system activities.
 *
 * OpenAPI spec version: v1
 *
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */


package com.ibm.risk.irmp.workflow.client.flowable.model;

import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.annotations.ApiModelProperty;
import java.time.OffsetDateTime;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * CmmnModel
 */

public class CmmnModel {
  @JsonProperty("id")
  private String id = null;

  @JsonProperty("name")
  private String name = null;

  @JsonProperty("targetNamespace")
  private String targetNamespace = null;

  @JsonProperty("expressionLanguage")
  private String expressionLanguage = null;

  @JsonProperty("exporter")
  private String exporter = null;

  @JsonProperty("exporterVersion")
  private String exporterVersion = null;

  @JsonProperty("author")
  private String author = null;

  @JsonProperty("creationDate")
  private OffsetDateTime creationDate = null;

  @JsonProperty("cases")
  private List<ModelCase> cases = null;

  @JsonProperty("processes")
  private List<Process> processes = null;

  @JsonProperty("decisions")
  private List<Decision> decisions = null;

  @JsonProperty("associations")
  private List<Association> associations = null;

  @JsonProperty("locationMap")
  private Map<String, GraphicInfo> locationMap = null;

  @JsonProperty("labelLocationMap")
  private Map<String, GraphicInfo> labelLocationMap = null;

  @JsonProperty("flowLocationMap")
  private Map<String, List<GraphicInfo>> flowLocationMap = null;

  @JsonProperty("primaryCase")
  private ModelCase primaryCase = null;

  @JsonProperty("namespaces")
  private Map<String, String> namespaces = null;

  public CmmnModel id(String id) {
    this.id = id;
    return this;
  }

   /**
   * Get id
   * @return id
  **/
  @ApiModelProperty(value = "")
  public String getId() {
    return id;
  }

  public void setId(String id) {
    this.id = id;
  }

  public CmmnModel name(String name) {
    this.name = name;
    return this;
  }

   /**
   * Get name
   * @return name
  **/
  @ApiModelProperty(value = "")
  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public CmmnModel targetNamespace(String targetNamespace) {
    this.targetNamespace = targetNamespace;
    return this;
  }

   /**
   * Get targetNamespace
   * @return targetNamespace
  **/
  @ApiModelProperty(value = "")
  public String getTargetNamespace() {
    return targetNamespace;
  }

  public void setTargetNamespace(String targetNamespace) {
    this.targetNamespace = targetNamespace;
  }

  public CmmnModel expressionLanguage(String expressionLanguage) {
    this.expressionLanguage = expressionLanguage;
    return this;
  }

   /**
   * Get expressionLanguage
   * @return expressionLanguage
  **/
  @ApiModelProperty(value = "")
  public String getExpressionLanguage() {
    return expressionLanguage;
  }

  public void setExpressionLanguage(String expressionLanguage) {
    this.expressionLanguage = expressionLanguage;
  }

  public CmmnModel exporter(String exporter) {
    this.exporter = exporter;
    return this;
  }

   /**
   * Get exporter
   * @return exporter
  **/
  @ApiModelProperty(value = "")
  public String getExporter() {
    return exporter;
  }

  public void setExporter(String exporter) {
    this.exporter = exporter;
  }

  public CmmnModel exporterVersion(String exporterVersion) {
    this.exporterVersion = exporterVersion;
    return this;
  }

   /**
   * Get exporterVersion
   * @return exporterVersion
  **/
  @ApiModelProperty(value = "")
  public String getExporterVersion() {
    return exporterVersion;
  }

  public void setExporterVersion(String exporterVersion) {
    this.exporterVersion = exporterVersion;
  }

  public CmmnModel author(String author) {
    this.author = author;
    return this;
  }

   /**
   * Get author
   * @return author
  **/
  @ApiModelProperty(value = "")
  public String getAuthor() {
    return author;
  }

  public void setAuthor(String author) {
    this.author = author;
  }

  public CmmnModel creationDate(OffsetDateTime creationDate) {
    this.creationDate = creationDate;
    return this;
  }

   /**
   * Get creationDate
   * @return creationDate
  **/
  @ApiModelProperty(value = "")
  public OffsetDateTime getCreationDate() {
    return creationDate;
  }

  public void setCreationDate(OffsetDateTime creationDate) {
    this.creationDate = creationDate;
  }

  public CmmnModel cases(List<ModelCase> cases) {
    this.cases = cases;
    return this;
  }

  public CmmnModel addCasesItem(ModelCase casesItem) {
    if (this.cases == null) {
      this.cases = new ArrayList<ModelCase>();
    }
    this.cases.add(casesItem);
    return this;
  }

   /**
   * Get cases
   * @return cases
  **/
  @ApiModelProperty(value = "")
  public List<ModelCase> getCases() {
    return cases;
  }

  public void setCases(List<ModelCase> cases) {
    this.cases = cases;
  }

  public CmmnModel processes(List<Process> processes) {
    this.processes = processes;
    return this;
  }

  public CmmnModel addProcessesItem(Process processesItem) {
    if (this.processes == null) {
      this.processes = new ArrayList<Process>();
    }
    this.processes.add(processesItem);
    return this;
  }

   /**
   * Get processes
   * @return processes
  **/
  @ApiModelProperty(value = "")
  public List<Process> getProcesses() {
    return processes;
  }

  public void setProcesses(List<Process> processes) {
    this.processes = processes;
  }

  public CmmnModel decisions(List<Decision> decisions) {
    this.decisions = decisions;
    return this;
  }

  public CmmnModel addDecisionsItem(Decision decisionsItem) {
    if (this.decisions == null) {
      this.decisions = new ArrayList<Decision>();
    }
    this.decisions.add(decisionsItem);
    return this;
  }

   /**
   * Get decisions
   * @return decisions
  **/
  @ApiModelProperty(value = "")
  public List<Decision> getDecisions() {
    return decisions;
  }

  public void setDecisions(List<Decision> decisions) {
    this.decisions = decisions;
  }

  public CmmnModel associations(List<Association> associations) {
    this.associations = associations;
    return this;
  }

  public CmmnModel addAssociationsItem(Association associationsItem) {
    if (this.associations == null) {
      this.associations = new ArrayList<Association>();
    }
    this.associations.add(associationsItem);
    return this;
  }

   /**
   * Get associations
   * @return associations
  **/
  @ApiModelProperty(value = "")
  public List<Association> getAssociations() {
    return associations;
  }

  public void setAssociations(List<Association> associations) {
    this.associations = associations;
  }

  public CmmnModel locationMap(Map<String, GraphicInfo> locationMap) {
    this.locationMap = locationMap;
    return this;
  }

  public CmmnModel putLocationMapItem(String key, GraphicInfo locationMapItem) {
    if (this.locationMap == null) {
      this.locationMap = new HashMap<String, GraphicInfo>();
    }
    this.locationMap.put(key, locationMapItem);
    return this;
  }

   /**
   * Get locationMap
   * @return locationMap
  **/
  @ApiModelProperty(value = "")
  public Map<String, GraphicInfo> getLocationMap() {
    return locationMap;
  }

  public void setLocationMap(Map<String, GraphicInfo> locationMap) {
    this.locationMap = locationMap;
  }

  public CmmnModel labelLocationMap(Map<String, GraphicInfo> labelLocationMap) {
    this.labelLocationMap = labelLocationMap;
    return this;
  }

  public CmmnModel putLabelLocationMapItem(String key, GraphicInfo labelLocationMapItem) {
    if (this.labelLocationMap == null) {
      this.labelLocationMap = new HashMap<String, GraphicInfo>();
    }
    this.labelLocationMap.put(key, labelLocationMapItem);
    return this;
  }

   /**
   * Get labelLocationMap
   * @return labelLocationMap
  **/
  @ApiModelProperty(value = "")
  public Map<String, GraphicInfo> getLabelLocationMap() {
    return labelLocationMap;
  }

  public void setLabelLocationMap(Map<String, GraphicInfo> labelLocationMap) {
    this.labelLocationMap = labelLocationMap;
  }

  public CmmnModel flowLocationMap(Map<String, List<GraphicInfo>> flowLocationMap) {
    this.flowLocationMap = flowLocationMap;
    return this;
  }

  public CmmnModel putFlowLocationMapItem(String key, List<GraphicInfo> flowLocationMapItem) {
    if (this.flowLocationMap == null) {
      this.flowLocationMap = new HashMap<String, List<GraphicInfo>>();
    }
    this.flowLocationMap.put(key, flowLocationMapItem);
    return this;
  }

   /**
   * Get flowLocationMap
   * @return flowLocationMap
  **/
  @ApiModelProperty(value = "")
  public Map<String, List<GraphicInfo>> getFlowLocationMap() {
    return flowLocationMap;
  }

  public void setFlowLocationMap(Map<String, List<GraphicInfo>> flowLocationMap) {
    this.flowLocationMap = flowLocationMap;
  }

  public CmmnModel primaryCase(ModelCase primaryCase) {
    this.primaryCase = primaryCase;
    return this;
  }

   /**
   * Get primaryCase
   * @return primaryCase
  **/
  @ApiModelProperty(value = "")
  public ModelCase getPrimaryCase() {
    return primaryCase;
  }

  public void setPrimaryCase(ModelCase primaryCase) {
    this.primaryCase = primaryCase;
  }

  public CmmnModel namespaces(Map<String, String> namespaces) {
    this.namespaces = namespaces;
    return this;
  }

  public CmmnModel putNamespacesItem(String key, String namespacesItem) {
    if (this.namespaces == null) {
      this.namespaces = new HashMap<String, String>();
    }
    this.namespaces.put(key, namespacesItem);
    return this;
  }

   /**
   * Get namespaces
   * @return namespaces
  **/
  @ApiModelProperty(value = "")
  public Map<String, String> getNamespaces() {
    return namespaces;
  }

  public void setNamespaces(Map<String, String> namespaces) {
    this.namespaces = namespaces;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    CmmnModel cmmnModel = (CmmnModel) o;
    return Objects.equals(this.id, cmmnModel.id) &&
        Objects.equals(this.name, cmmnModel.name) &&
        Objects.equals(this.targetNamespace, cmmnModel.targetNamespace) &&
        Objects.equals(this.expressionLanguage, cmmnModel.expressionLanguage) &&
        Objects.equals(this.exporter, cmmnModel.exporter) &&
        Objects.equals(this.exporterVersion, cmmnModel.exporterVersion) &&
        Objects.equals(this.author, cmmnModel.author) &&
        Objects.equals(this.creationDate, cmmnModel.creationDate) &&
        Objects.equals(this.cases, cmmnModel.cases) &&
        Objects.equals(this.processes, cmmnModel.processes) &&
        Objects.equals(this.decisions, cmmnModel.decisions) &&
        Objects.equals(this.associations, cmmnModel.associations) &&
        Objects.equals(this.locationMap, cmmnModel.locationMap) &&
        Objects.equals(this.labelLocationMap, cmmnModel.labelLocationMap) &&
        Objects.equals(this.flowLocationMap, cmmnModel.flowLocationMap) &&
        Objects.equals(this.primaryCase, cmmnModel.primaryCase) &&
        Objects.equals(this.namespaces, cmmnModel.namespaces);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, name, targetNamespace, expressionLanguage, exporter, exporterVersion, author, creationDate, cases, processes, decisions, associations, locationMap, labelLocationMap, flowLocationMap, primaryCase, namespaces);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class CmmnModel {\n");

    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    targetNamespace: ").append(toIndentedString(targetNamespace)).append("\n");
    sb.append("    expressionLanguage: ").append(toIndentedString(expressionLanguage)).append("\n");
    sb.append("    exporter: ").append(toIndentedString(exporter)).append("\n");
    sb.append("    exporterVersion: ").append(toIndentedString(exporterVersion)).append("\n");
    sb.append("    author: ").append(toIndentedString(author)).append("\n");
    sb.append("    creationDate: ").append(toIndentedString(creationDate)).append("\n");
    sb.append("    cases: ").append(toIndentedString(cases)).append("\n");
    sb.append("    processes: ").append(toIndentedString(processes)).append("\n");
    sb.append("    decisions: ").append(toIndentedString(decisions)).append("\n");
    sb.append("    associations: ").append(toIndentedString(associations)).append("\n");
    sb.append("    locationMap: ").append(toIndentedString(locationMap)).append("\n");
    sb.append("    labelLocationMap: ").append(toIndentedString(labelLocationMap)).append("\n");
    sb.append("    flowLocationMap: ").append(toIndentedString(flowLocationMap)).append("\n");
    sb.append("    primaryCase: ").append(toIndentedString(primaryCase)).append("\n");
    sb.append("    namespaces: ").append(toIndentedString(namespaces)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}
